import request from '@/utils/request'

// 保存账单
export function saveBill(data) {
  return request({
    url: '/manage/bills',
    method: 'post',
    data: data
  })
}

// 获取账单列表
export function getBillList(query) {
  return request({
    url: '/manage/bills/list',
    method: 'get',
    params: query
  })
}

// 删除账单
export function deleteBill(billId) {
  return request({
    url: '/manage/bills/' + billId,
    method: 'delete'
  })
}

// 获取账单详情
export function getBillDetail(billId) {
  return request({
    url: '/manage/bills/' + billId,
    method: 'get'
  })
}

// 修改账单
export function updateBill(data) {
  return request({
    url: '/manage/bills/edit',
    method: 'put',
    data: data
  })
} 